package whu.edu.demo.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import whu.edu.demo.domain.Supplier;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import java.util.List;
@Mapper
public interface SupplierDao extends BaseMapper<Supplier> {
    @Select("SELECT supplier.* FROM supplier,s_c WHERE s_c.cId = #{productId} && supplier.Id = s_c.sId")
    List<Supplier> findSupplierByCommodityId(int productId);
}
